package com.jiuzhou.surery.Controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RestController;

import jakarta.servlet.http.HttpServletRequest;

@RestController
public class HelloController {
    
    @GetMapping("/hello")
    public String hello(){
        return "Hello World";
    }

    @PostMapping("/submit")
    public String handle(HttpServletRequest request){
        String sex=request.getParameter("sex");
        String[] cloudserver=request.getParameterValues("cloudserver");
        String textarea=request.getParameter("textarea");
        String city=request.getParameter("city");
        String security=request.getParameter("security");
       

        return sex+"  "+cloudserver +"  "+ textarea+"   "+ city+"   "+ security;
    }
}
